home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
Shareware Overload Trio 1
/
Shareware Overload Trio Volume 1 (Chestnut CD-ROM).ISO
/
dir3
/
vendor28.zip
< prev
next >
Wrap
Text File
|
1994-08-08
|
31KB
|
939 lines
t" applied to them.
** This option is case sensitive. This means that "Secret", "secret" and
"SECRET" are all different passwords.
See Also: "Using Data
Encryption", PKZIP -s
════════════════════════════════════════════════════════════════════════════
PKWARE Inc. PKUNZIP 53
_____________________________________
-t Test .ZIP file integrity
This option is used to test files within a .ZIP file in order to verify that
they are valid and have not been corrupted. PKUNZIP will perform all the
actions that would normally be taken during a .ZIP file extraction, except
that files will not be written to disk.
The data will be extracted and checked against the CRC to ensure it's val-
idity. After each file is checked it's name will be displayed with an "OK".
C:\PKSTUFF>pkunzip zc102 -t
Searching ZIP: ZC102.ZIP - PKWARE Support BBS (414)354-8670
Testing: ZC.DOC OK
Testing: ZC.EXE OK
Testing: ORDER.FRM OK
Testing: VER-HIST.TXT OK
In this example a command is issued which performs a test on the .ZIP file
"zc102". As each file is tested its name is displayed. Note that the .ZIP
file comment is displayed.
If you test a file that is not a .ZIP file, or specify particular files
within the .ZIP file that do not exist, you will receive the message:
PKUNZIP: (E11) No file(s) found.
Testing a .ZIP file with errors would produce a display something like this:
Searching ZIP: PROBLEM.ZIP
Testing: WORLD.M~ PKUNZIP: (W15) Warning! file fails CRC check
Testing: CORELDRW.BPT OK
PROBLEM.ZIP has errors!
Normally, a CRC failure as above indicates that a file has been damaged
either in storage or transmission. For instructions on attempting to repair
a .ZIP file that has been corrupted, see PKZIPFIX in the Trouble Shooting
section.
See Also: "Trouble Shooting", "F.A.Q."
════════════════════════════════════════════════════════════════════════════
54 PKUNZIP PKZIP 2
_____________________________________
-v[b][r,c|d|e|n|p|s][m] View [brief] file information
-vt[m] View Technical file information
The -v option for PKUNZIP is the same as the -v option for PKZIP, with one
exception. In PKUNZIP the `c' option for sorting refers to the CRC value.
For PKUNZIP this option refers to the Comment of a file.
For complete information, please see the -v option in the PKZIP Command
Reference.
See Also: PKZIP -v
_____________________________________
-x<filespec> Exclude files from extraction
-x@list.lst Exclude list of files from extraction
By specifying a -x as part of the PKUNZIP command, you may prevent a file or
group of files from being extracted. Using -x with a list file will allow
you to exclude a list of files from extraction.
pkunzip fd201.zip -x*.doc
In this example all files are extracted from the .ZIP file "fd201.zip" except
for those with a ".doc" extension.
-x may be used more than once on the command line, and may be used in
combination with specific filespecs and list files.
See Also: PKZIP -x
_____________________________________
-$ Restore volume label
This command is used to restore any volume label that has been stored in the
.ZIP file. It is important to remember that the PKZIP command used to store
a volume label does not store a drive letter along with the label. Upon
extraction, the volume label will be assigned to the target drive.
C:\>pkunzip davebk.zip -$ a:
This example will extract the contents of "davebk.zip" to the A: drive. If a
volume label was stored as part of the .ZIP file, the volume label for the
floppy in drive A: will be reset to the one contained in davebk.zip.
See Also: PKZIP -$
════════════════════════════════════════════════════════════════════════════
PKWARE Inc. PKUNZIP 55
_____________________________________
-@filename.lst Generate LIST file
Please note that this option is different from using a list file. When a
list file is to be read by PKZIP there is no dash in front of the @.
Using this option will cause a list file to be generated using the specified
file name instead of a normal PKUNZIP operation being performed. The output
file will be a plain ASCII file with one file name per line, and will be
identical to the listing of files PKUNZIP would have extracted had the -@
option not been used.
pkunzip underdem.zip -@showme.lst
This would create a list file called "showme.lst" containing a list of all
the files present within the .ZIP file. File specs may be used in
conjunction with this type of command, in the same manner as a normal
extraction command. Also the -e option may be used for sorting. The
following example creates an alphabetized list file of only the ".doc" files
within it:
pkunzip manuals.zip -en *.doc -@docs.lst
The extension of ".lst" on a list file is not mandatory, but recommended for
clarity.
See Also: "Using List Files",
PKZIP @, -@
════════════════════════════════════════════════════════════════════════════
56 PKUNZIP PKZIP 2
PKSFX/ZIP2EXE
════════════════════════════════════════════════════════════════════════════
The PKZIP utilities offer a self-extraction capability. This means that you
can make a .ZIP file into an .EXE file. This file will in effect be able to
extract itself. A PKSFX (PK-Self Extracting) file consists of a .ZIP file
which has been transformed into a self-extracting file by the utility
ZIP2EXE. There is no utility or file called "SFX" or "PKSFX", but the
self-extracting file will show PKSFX on the banner in the same manner as
PKUNZIP:
PKSFX (R) FAST! Self Extract Utility Version 2
Copr. 1989-1992 PKWARE Inc. All Rights Reserved. PKSFX/h for help
PKSFX Reg. U.S. Pat. and Tm. Off.
Creating a Self-Extracting File
In order to create a self-extracting file, you must first create a .ZIP file.
Once this .ZIP file is created, use the ZIP2EXE utility to transform this
.ZIP file into an .EXE file.
D:\>zip2exe test.zip
ZIP2EXE (tm) Self-Extract Creator Version 2
Copr. 1989-1992 PKWARE Inc. All Rights Reserved. ZIP2EXE/h for help
TEST.ZIP => TEST.EXE
D:\>
As you can see, an .EXE file by the same name as the .ZIP file is created.
The original .ZIP file is not deleted.
Meet Junior
** Turning a .ZIP file into an .EXE file increases the size because of the
included extraction program. The added size is approximately 13.5K
bytes. If space is at a premium, and you are willing to sacrifice
functionality for size, try PKSFX Junior(TM).
The PKSFX Junior is somewhat smaller, and offers very few command line
options due to this reduced size. The options which are available with
the PKSFX Junior are indicated on the PKSFX command summary.
To create a PKSFX Junior file, add the command line option -j when performing
the ZIP2EXE step.
════════════════════════════════════════════════════════════════════════════
PKWARE Inc. PKSFX/ZIP2EXE 57
D:\>zip2exe -j test.zip
** PKSFX Junior adds approximately 3K bytes to the .ZIP file.
PKSFX Junior can handle a maximum of 512 files. Although PKSFX Junior has
this limit to the number of files it can handle, there is no limit to the
file size.
PKUNZIP Junior
════════════════════════════════════════════════════════════════════════════
PKUNZJR.COM
The PKUNZIP Junior program is an extremely small stand-alone extraction
program. It is used in the same manner as PKUNZIP but it has only the
functionality of the PKSFX Junior self-extractor.
PKUNZIP(R) FAST! Mini Extract Utility Version 2
Copr. 1989-1992 PKWARE Inc. All Rights Reserved.
PKUNZIP Reg. U.S. Pat. and Tm. Off.
Usage: pkunzjr [-o] filename[.zip] [output_path]
PKUNZIP Junior has one option, -o. This option is the same as that for
PKUNZIP (Senior).
PKUNZIP Junior accepts the .ZIP file name on the command line, and may
optionally accept an output path. PKUNZIP Junior cannot extract specific
files, but must extract the entire .ZIP file.
PKUNZIP Junior cannot extract a file containing more that 512 files, and does
not support multiple volume .ZIP files.
════════════════════════════════════════════════════════════════════════════
58 Introduction PKZIP 2
PKSFX Command Summary
Command line syntax and options are the same as PKUNZIP. The options listed
below are offered by a self-extracting file.
Syntax: pksfx [option] [d:\path] [file]* [file]*
PKSFX indicates the name of the self-extracting file you are executing. No
options are necessary if you wish to simply extract all files to the current
directory. If you wish to extract the contents to another directory,
indicate the drive and/or path the files should extract to. To extract only
particular files, indicate the name(s) at the end of the command line.
Options:
@listfile.lst Specify list of files for extraction*
-c[m] Extract to console*
-d Re-create directories stored in .ZIP file*
-l Display software license agreement*
-n Extract only newer files*
-o Overwrite existing files
-p[a|b][c][#] Extract to printer*
-s<password> Decrypt with password*
-t Test file integrity*
*Indicates options not available in the PKSFX Junior and PKUNZIP Junior
programs.
Options should be placed after the self-extracting files name. If multiple
options are used they must be separated by a space and each must have its own
option indicator (either - or /).
All options behave in the same manner as they do with PKUNZIP, with one
exception. The -s option cannot accept keyboard entry. A password entered
with a self-extracting file must be able to be entered from the command line.
════════════════════════════════════════════════════════════════════════════
PKWARE Inc. PKSFX/ZIP2EXE 59
Modifying a Self-Extracting File
A self-extracting file can be operated upon by PKZIP and PKUNZIP in a manner
identical to normal .ZIP files. You will need to specify the full file name
including the EXE extension.
C:\>pkzip test.exe -f d:\*.*
There is no difference between operating on a self-extracting file and a
normal .ZIP file.
A Note About Self-Extracting Files
When you create a self-extracting file, you are adding a copy of the
extraction code to that file. Since this code duplicates the functionality
of the PKUNZIP program, it makes sense to use the self-extractor only when
PKUNZIP will not be present on the machine to extract the file.
If you create many self-extracting files for your own use, you will be using
more space unnecessarily. Therefore it is recommended that you only use the
self-extracting capability when you are sending a file to someone that you
know does not have a compatible PKUNZIP.
Stripping the PKSFX Code
You may have occasion to want to keep the contents of a self-extracting file,
but wish to turn it back to a normal .ZIP file.
The ZIP2EXE offers an option to reverse the process. This is done with the
command line switch -e:
F:\>zip2exe -e test.exe
ZIP2EXE will recognize normal and PKSFX Junior files automatically.
Sending a Self-Extractor
If you are sending a PKSFX file to somone who is not familiar with data
compression and/or PKWARE products, we recommend you tell them to do the
following:
════════════════════════════════════════════════════════════════════════════
60 Introduction PKZIP 2
With PKSFX Junior:
1) Create a temporary directory on the hard drive to hold the
files contained in the self-extracting file.
C:\>md temp
2) Change to the directory that was just created.
C:\>cd temp
C:\temp>
3) Place the diskette containing the self-extracting file into
the A: or B: drive. 4) Type the name of the self-extractor,
including the path to the floppy drive.
C:\temp>a:test
With normal PKSFX:
1) Place the diskette containing the self-extracting file into
the A: or B: drive and change to that drive.
C:\>a:
2) Type in the following;
A:\>test -d c:\temp
You may also wish to create a batch file or text file on the floppy disk
containing the above steps. The contents of the self-extractor will be placed
into this temporary directory. They can then examine or move the files at
their leisure. The -d option ensures that any subdirectory information
included will be re-created, and causes PKSFX to create the temporary
directory for the user.
────────────────────────────────────────────────────────────────────────────
A site license is required by a corporation, company, educational
institution, or governmental agency for use of PKWARE software on the total
number of computers that will use the software.
Use of PKWARE programs for personal use is covered by your purchase of a
single license for PKZIP. A Distribution License is required by a
corporation, company, educational institution or governmental agency to use
PKWARE programs to facilitate the distribution of software to outside parties.
Please note that if a self-extracting file is used, a Distribution License is
required, because PKWARE code is distributed in the form of the PKSFX program
combined with the file(s) being distributed.
Please contact PKWARE for more information if you intend to distribute self-
extracting files.
════════════════════════════════════════════════════════════════════════════
PKWARE Inc. PKSFX/ZIP2EXE 61
Confirm before extract
If a PKSFX file has a .ZIP file comment attached, this comment is displayed
before the file is extracted. By imbedding a Control-S character (Hex 13,
ASCII 19), you can cause PKSFX to pause. The display will look like this:
Searching EXE: XXXXX.EXE -
.
.
.
(ZIP file comment text)
.
.
.
Do you want to extract these files now (y/n)?
Press 'Y' to extract the files, 'N' o abort. Note that the Control-S
character is not displayed. This control character may be located anywhere
within the comment.
If the user aborts by pressing 'N', an exit code of 12 will be returned by
PKSFX. PKSFX Junior will return an exit code of 8.
See: PKZIP -z for more
information on .ZIP file
comments, Appendix D for
more information on exit codes.
Memory Requirements
The memory requirements for PKSFX are similar to those of PKUNZIP.
PKSFX Junior, and PKUNZIP Junior require a minimum of 50K RAM free, and a
maximum of 64K RAM free.
════════════════════════════════════════════════════════════════════════════
62 Introduction PKZIP 2
USING LIST FILES
════════════════════════════════════════════════════════════════════════════
PKZIP, PKUNZIP and PKSFX offer a powerful feature; list files. List files are
simply listings of files. They are used to simplify command lines, and make
repetitive tasks less troublesome.
List files can allow you to perform some complex tasks which otherwise would
not be possible. List files can not only be read, but can also be created by
PKZIP and PKUNZIP. Also, list files can be created and used by other programs,
such as StupenDOS", PKZOOM" and PKZMENU".
PKZIP and PKUNZIP use List Files in two ways: files to be included and files
to be excluded. If a List File is being created, the contents will reflect a
listing of those files which would have been added, deleted, extracted or
listed during a normal PKZIP/PKUNZIP operation.
List File text may contain:
-> Comments
-> File Names
-> Wild Cards
-> Exact Path Names and Files
-> Drive Letters
List File text consists of plain ASCII. These files may be created using any
text editor which can produce plain ASCII files, sometimes referred to as "DOS
Text".
All of the following lines would be valid in a List File:
clowns.bmp
*.exe
project.*
MSLR????.QWK
;This is a comment
emp\census.txt ;This is also a valid comment
D:\data\february.wk1
D:\games\majong\*.*
D:\QWK\*.REP
A line in a list file is treated in an identical manner to files specified on
the command line. Note that only files and comments are valid in a list file.
Both forward and backward slashes may be used in a list file.
════════════════════════════════════════════════════════════════════════════
PKWARE Inc. Using List Files 63
Reading List Files
A list file can be used in two different ways with PKZIP and PKUNZIP:
-> Files to be acted upon in a ZIP operation.
-> Files to be excluded from a ZIP operation.
List files are usually specified with an @ (ASCII 64, normally above the 2 on
your keyboard). The list file character can be changed by modifying the
configuration file. Please note that the list file generation option (-@))
will also change to the selected list file character. Avoid using a character
already used for another option.
The simplest example of using a List File is when a .ZIP file is going to be
created containing the files specfied. If a List File called "test.lst" was
created containing the following lines:
*.COM
300Z.TXT
And then used in a PKZIP command:
C:\>pkzip sample.zip @test.lst
All .COM files in the current directory would be added to the .ZIP file
"SAMPLE.ZIP", as well as the file "300Z.TXT" if it existed.
The contents of a List File that is specified are included. The contents of a
List File specified after a -x are excluded. Multiple List Files to be
included and excluded may be specified on the command line in addition to file
names being listed alone on the command line.
Following are several example usages of List Files, each with a short
description of what action would be caused.
C:\>pkzip first.zip @abc.lst -x@xyz.lst
All files specified in "abc.lst" would be added to the .ZIP file "first.zip".
Any files that match the file specification in "xyz.lst" would not be added.
C:\>pkzip second.zip -d @abc.lst -x*.txt
All files listed in "abc.lst" would be deleted from the .ZIP file "first.zip".
Any files matching the "*.txt" specification would not be deleted.
C:\>pkzip -vc third.zip @xyz.lst
════════════════════════════════════════════════════════════════════════════
64 Introduction PKZIP 2
A file listing with comments will be shown for all files in "third.zip" which
are listed in "xyz.lst"
C:\>pkzip -rp backup.zip *.* -x@noback.lst
A .ZIP file containing the entire drive would be created, excluding any files
which match those in "noback.lst"
** Don't forget to use the @ in front of a list file name. If you do not use
the @, the list file itself will be added to the .ZIP file.
Generating List Files
The Generation of list files can have many uses. Some suggested ways to use
this feature are:
-> Dividing Files to be Zipped into logical groups
-> Easy exclusion of files already Zipped from a PKZIP operation
-> Complex Batch File operations
Keep in mind that a plain ASCII list file can be fed through other programs,
like 'sort', and can be used by some other applications such as StupenDOS or
PKZMENU.
The list file generated by PKZIP or PKUNZIP when the -@ option is used
contains the names of all the files which would have been acted upon in a
normal ZIP operation.
In a simple PKZIP command, the list file will contain a listing of all the
files which would have been archived by PKZIP. If the list file is generated
with a freshen or update command, the list file will contain those files which
would have been added/updated in the .ZIP file.
To generate a list file of your entire C: hard drive:
C:\>pkzip dummy -rp -@cdrive.lst
Note that the "dummy" .ZIP file name is necessary to have a valid PKZIP
command.
The list file generated by PKUNZIP will contain those files which would have
been extracted.
════════════════════════════════════════════════════════════════════════════
PKWARE Inc. Using List Files 65
Using List files to debug
You may find the generation of list files helpful when you are testing batch
files. Let's say you have created a batch file which should compress several
files as a backup procedure. Perhaps these files are very large and it takes
several minutes to compress each one. This means that if you were to test the
batch file simply by running it, it could take quite a while to find a problem
and fix it.
By generating a list file of what would have been compressed, you can check
very quickly to make certain that the proper files are being selected.
List file size
The size of a list file that may be processed is limited. The total size of
the list file depends upon two factors.
The first is path storage. If paths are specified in the list file and are
NOT stored with the -P option, the list file size is limited to 7000 bytes.
If paths are specified and ARE stored, the list file size is limited to 9700
bytes.
If a list file has drive letters specified as part of the file names within
the file, the maximum list file size is reduced. When paths are not stored
the maximum List File size is 5100 bytes. When they are stored the maximum
List File size is 6600 bytes.
Note that this table corresponds to the total size of all list files being
used in a single command.
╔════════════════════════════╤══════════════════╤═══════════════════╗
║ List File Size Limits │ No Path Storage │ Path Storage (-P) ║
╟────────────────────────────┼──────────────────┼───────────────────╢
║ Drive Letters in List File │ 5100 bytes* │ 6600 ║
╟────────────────────────────┼──────────────────┼───────────────────╢
║ No Drive Letter │ 7000 │ 9700 ║
╚════════════════════════════╧══════════════════╧═══════════════════╝
*These numbers are approximate and may vary depending on your
configuration.
If the list file is too big, you will receive an "Insufficient Memory" error.
If you have a list file which is too big, you may split it into two or more
smaller list files and perform multiple PKZIP operations.
════════════════════════════════════════════════════════════════════════════
66 Introduction PKZIP 2
Be Creative
The list file functions give you a whole new level of power with PKZIP. When
defining a problem and searching for a solution, don't forget to consider the
power of these features.
Using the list file features can give you access to new abilities PKZIP would
not have inherently. Here are some example situtations:
Removing Old Files
Suppose a .ZIP file 'work' contains 45 files. The contents of 'work' are
extracted to a work directory and several of the files are deleted. How do
you delete these files that are no longer necessary from the 'work' archive?
Doing it manually would be very tedious.
First create a list of the contents of the directory. By redirecting these
file names to a list file you can capture an image of what needs to be kept in
the .ZIP file.
C:\work>pkzip dummy.zip *.* -@keep.lst
The list file 'keep.lst' now contains the files we want preserved in the .ZIP
file, files not in this list will be deleted:
C:\work>pkzip work.zip -d *.* -x@keep.lstC:\work>del keep.lst
The WORK.ZIP file now contains only those files which are also in the work
directory.
Sorting .ZIP Files
Files will be added to a .ZIP file in the order that they are listed in the
list file. This can be useful if you want the contents of a .ZIP file to be
in a particular order. After generating a list file, bring it into an editor
and modify it to meet your need. To create a .ZIP file that is sorted in
alphabetical order, you would use the following series of commands:
C:\work>pkzip test.zip *.* -@test.lst
C:\work>sort < test.lst > sort.lst
C:\work>pkzip test.zip @sort.lst
C:\work>del test.lst sort.lst
The SORT command used above is a standard DOS program. See your DOS
manual for further information on this useful feature.
════════════════════════════════════════════════════════════════════════════
PKWARE Inc. Using List Files 67
USING DATA ENCRYPTION
════════════════════════════════════════════════════════════════════════════
The PKZIP utilities offer the ability to protect stored data through
encryption. You should use PKZIP's encryption ability in place of any other
encryption on files you intend to compress.
This encryption ability has been made integral to the function of PKZIP and
PKUNZIP to prevent the encryption from interfering with PKZIP's ability to
compress. If you feel the need to encrypt your data to protect it, and are
intending to compress the data as well, you should then use the encryption of
PKZIP. Using the encryption capability of a spreadsheet or database program
will prevent PKZIP from compressing the data efficiently.
Encryption is enabled in PKZIP by use of the -s option. The encryption key,
sometimes referred to as a "password", follows directly after the -s
C:\>pkzip test.zip -ssecret d:\payroll\*.dbf
Above, all the "dbf" files from the payroll directory have been compressed
into a .ZIP file called "test.zip". During the compression they are also
being encrypted based upon the key of "secret".
The encryption scheme used by PKZIP is complex and robust. The encryption key
is used to generate a number of binary encryption keys which are in turn used
to determine how the compressed data is altered. Neither the original key or
the derived keys are stored with the .ZIP file, nor are they retained anywhere
else for that matter. This means you must remember the encryption key.
╔═══════════════════════════════════════════════════════════════════╗
║ IF YOU LOSE THE ORIGINAL ENCRYPTION KEY YOU WILL NEVER BE ABLE TO ║
║ EXTRACT THE FILE(S). ║
╚═══════════════════════════════════════════════════════════════════╝
It is also not possible to derive the original keys by examining the
compressed data, or by analysis of original data versus encrypted data. This
means that if you loose the key, there is no way to find it. PKWARE Inc. has
no special means or technology for deriving the key or extracting the data
without the key.
Also note that a minute change in the key completely alters the encryption
scheme. This means that the key must be exact. Any change in spelling,
capitalization or punctuation causes a key to be completely different. Be
certain that you know what the encryption key is and will not lose, forget, or
mistype it.
════════════════════════════════════════════════════════════════════════════
68 Introduction PKZIP 2
╔════════════════════════════════════════════════╗
║ DO NOT TRUST YOUR MEMORY ALONE. WRITE IT DOWN.║
╚════════════════════════════════════════════════╝
Capitalization is also important. "Secret", "secret" and "SECRET" are all
completely different encryption keys.
You should realize that a person who knows you could attempt to extract a file
you have encrypted by using words they think you will use or can remember
easily. This would be items such as:
≡ Your Spouse's name
≡ Your Social Security Number
≡ Your Address
≡ Your Dog's name
≡ Etc...
Long Keys
It is possible to have extremely long keys, or keys with spaces in them. The
length of the encryption key is limited only by the length of a DOS command
line. To use a key with spaces in it, you must enclose the password in
quotation marks:
C:\>pkzip test.zip -s"mary had a little lamb" *.dbf
Passwords of this sort may be easy to remember, while proving to be very
secure. Remember to use phrases that are not obvious to someone who knows you.
Complex Keys
If PKZIP or PKUNZIP is specified with only the -s and no encryption key
following, the user is prompted for an encryption key.
════════════════════════════════════════════════════════════════════════════
PKWARE Inc. Using Data Encryption 69
C:\>zip test -s *.com
PKZIP (R) FAST! Create/Update Utility Version 2
Copr. 1989-1992 PKWARE Inc. All Rights Reserved. PKZIP/h for help
PKZIP Reg. U.S. Pat. and Tm. Off. Patent No. 5,051,745
Password ? ******
■80486 CPU detected.
■XMS version 2.00 detected.
■Novell Netware version 3.11 detected.
■Using Super Fast Compression.
Creating ZIP: TEST.ZIP
Adding: COMMAND.COM Deflating (36%), done.
Adding: 4DOS.COM Deflating (34%), done.
Asterisks are displayed in place of each character as you enter the encryption
key. This feature offers added security in the event somone is watching as
you type in the password.
This method of entry may be easier or more comfortable to use. This also
allows you to enter characters for the encryption key which cannot normally be
entered from the keyboard.
In order to enter one of these characters, hold down the [ALT]